import { express } from '@/utils/express/express.js'
import isToken from '@/utils/token/token.js'

export const history_search = (data) => {
  return express.get('api/search_hot', data)
}

export const search = (data) => {
  return express.get('api/search', {
    params: { content: data }
  })
}

export const searchWithToken = (data) => {
  return express.get('user/search', {
    headers: {
      'Authorization': isToken()
    },
    params: { content: data }
  })
}